package rpc_netty.LoadBalancerImpl;

import rpc_netty.interfaces.LoadBalancer;

public class LoadBalancerProvider {
    public static LoadBalancer getLoadBalancerByName(String name){
        switch (name){
            case "Random":
                return new RandomLoadBalancer();
            case "RoundRobin":
                return new RoundRobinLoadBalancer();
            default:
                return new RandomLoadBalancer();
        }
    }
}
